- SQL commands designed to interact and manipulate the data stored within database tables.
- The command is not auto-committed (It can't permanently save all the changes in the database) they can be rollbacked.
Insert single row:
INSERT INTO employee(first_name, last_name, email)
VALUES('Kirankumar', 'Yadav', 'kirankumar.yadav@gmail.com');Insert multiple rows:
INSERT INTO employee(first_name, last_name, email)
VALUES('Kirankumar', 'Yadav', 'kirankumar.yadav@gmail.com'),
('Kisankumar', 'Yadav', 'kisankumar.yadav@gmail.com'),
('Rohit', 'Yadav', 'rohit.yadav@gmail.com'),
('Arpit', 'Yadav', 'arpit.yadav@gmail.com');Update the value of a column in a table:
UPDATE employee
SET designation = 'Data Scientist'
WHERE first_name = 'Kirankumar'
AND last_name = 'Yadav'
AND birth_date = '1996-02-07';Remove one or more rows from a table:
DELETE
FROM supplier
WHERE supplier_ID = 2;WHERE Clause is only used with DELETE command (Not with DROP and TRUNCATE commands)